const btn1 = document.getElementById('btn1')
btn1.onclick = () => {
    console.log(window)
}

const input = document.getElementById('input')
const btn2 = document.getElementById('btn2')
btn2.onclick = () => {
    electron.saveFile(input.value)
}

const btn3 = document.getElementById('btn3')
btn3.onclick = async () => {
    electron.readFile().then((res) => alert(res))
}

window.onload = () => {
    electron.getMessage((event, message) => {console.log(event, message)})
}

function logMessage(event, str) {
    console.log(event, str)
}